package com.matt.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.matt.domain.article.Article;
import com.matt.repository.article.ArticleRepository;
import com.matt.service.ArticleService;

@Service
public class AtricleServiceImpl implements ArticleService{
	@Autowired
	private ArticleRepository articleRepository;
	@Override
	public List<Article> getAtticleByTypeId(Integer id) {
		// TODO Auto-generated method stub
		return articleRepository.findByTypeId(id);
	}
	@Override
	public Article getAtticleById(String id) {
		// TODO Auto-generated method stub
		return articleRepository.getOne(id);
	}

}
